<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<c:set var="ctx" value="${pageContext.request.contextPath}"/>
<!DOCTYPE html>
<html lang="zh">
<head>
    <meta charset="utf-8"/>
    <title>Receiver-${interface_name}</title>
    <meta name="description" content="receive"/>
    <link rel="stylesheet" type="text/css" href="${ctx}/static/css/config.css"/>
</head>
<body>
<div class="config-block">
    <form action="${ctx}/message/receive" method="post">
        <div class="config-block">
            <div class="config-item">
                <span class="config-item-title">Initial Context Factory</span>
                <input class="config-item-input" type="text" id="initial_context_factory" name="initial_context_factory" title="Initial Context Factory"
                       value="com.tibco.tibjms.naming.TibjmsInitialContextFactory"/>
            </div>
            <div class="config-item">
                <span class="config-item-title">Connection URL</span>
                <input class="config-item-input" type="text" id="connection_url" name="connection_url" title="Connection URL" value="${connection_url}"/>
            </div>
            <div class="config-item">
                <span class="config-item-title">Connection Factory</span>
                <input class="config-item-input" type="text" id="connection_factory" name="connection_factory" title="Connection Factory" value="${connection_factory}"/>
            </div>
            <%--<div class="config-item">--%>
                <%--<span class="config-item-title">Select Queue Name</span>--%>
                <%--<select title="Queue Name" id="queue_name_list" name="queue_name_list" onchange="selectQueueName()">--%>
                    <%--<option value ="queue.sample">select queue name or enter a queue name below</option>--%>
                    <%--<option value ="RIL4G.INV.BillingAccountManagement.IssueNotifyBillingAccount.VerisCRMESB.Request.Q.V01">RIL4G.INV.BillingAccountManagement.IssueNotifyBillingAccount.VerisCRMESB.Request.Q.V01</option>--%>
                    <%--<option value ="RIL4G.INV.WorkOrderManagement.submitWorkOrder.Veris.Proxy.Request.Q.V01">RIL4G.INV.WorkOrderManagement.submitWorkOrder.Veris.Proxy.Request.Q.V01</option>--%>
                    <%--<option value="RIL4G.FUL.ServiceOrderManagement.receiveStatusUpdate.Veris.In.Q.V01">RIL4G.FUL.ServiceOrderManagement.receiveStatusUpdate.Veris.In.Q.V01</option>--%>
                    <%--<option value="RIL4G.FUL.ServiceOrderManagement.createServiceOrder.Veris.Out.Q.V01">RIL4G.FUL.ServiceOrderManagement.createServiceOrder.Veris.Out.Q.V01</option>--%>
                    <%--<option value="RIL4G.INV.WorkOrderManagement.submitWorkOrder.Veris.Proxy.Response.Q.V01">RIL4G.INV.WorkOrderManagement.submitWorkOrder.Veris.Proxy.Response.Q.V01</option>--%>
                    <%--<option value="RIL4G.FUL.MNP.sendMessage.Veris.Inbound.Q">RIL4G.FUL.MNP.sendMessage.Veris.Inbound.Q</option>--%>
                    <%--<option value="RIL4G.FUL.MNP.receiveMessage.Veris.Outbound.Q">RIL4G.FUL.MNP.receiveMessage.Veris.Outbound.Q</option>--%>
                    <%--<option value="RIL4G.INV.WorkOrderManagement.updateWorkOrder.Veris.Proxy.Request.Q.V01">RIL4G.INV.WorkOrderManagement.updateWorkOrder.Veris.Proxy.Request.Q.V01</option>--%>
                    <%--<option value="RIL4G.FUL.ServiceOrderManagement.submitNotification.OE.Out.Q.V01">RIL4G.FUL.ServiceOrderManagement.submitNotification.OE.Out.Q.V01</option>--%>
                    <%--<option value="RIL4G.BIL.JioMoney.NotificationUpdate.ESB.Request.Q.V01">RIL4G.BIL.JioMoney.NotificationUpdate.ESB.Request.Q.V01</option>--%>
                    <%--<option value="RIL4G.FUL.OrderPublication.OrderPublication.VERISCRM.Out.Q.V01">RIL4G.FUL.OrderPublication.OrderPublication.VERISCRM.Out.Q.V01</option>--%>
                    <%--<option value="RIL4G.INV.CustomerProfileManagement.IssueCustomerProfile.VERISCRM.Out.Q.V01">RIL4G.INV.CustomerProfileManagement.IssueCustomerProfile.VERISCRM.Out.Q.V01</option>--%>
                    <%--<option value="RIL4G.ASIAINFO.CustomerProblemManagement.IssueCustomerProblem.SAPCRMESB.Request.Q.V01">RIL4G.ASIAINFO.CustomerProblemManagement.IssueCustomerProblem.SAPCRMESB.Request.Q.V01</option>--%>
                    <%--<option value="RIL4G.FUL.ProductOrderManagement.issueInteractionOrder.SAPCRMESB.Request.Q.V01">RIL4G.FUL.ProductOrderManagement.issueInteractionOrder.SAPCRMESB.Request.Q.V01</option>--%>
                <%--</select>--%>
            <%--</div>--%>
            <div class="config-item">
                <span class="config-item-title">Enter Queue Name</span>
                <input class="config-item-input" type="text" id="queue_name" name="queue_name" title="Queue Name" value="${queue_name}"/>
            </div>
            <div class="config-item">
                <span class="config-item-title">Username</span>
                <input class="config-item-input" type="text" id="username" name="username" title="Username" value="${username}"/>
            </div>
            <div class="config-item">
                <span class="config-item-title">Password</span>
                <input class="config-item-input" type="text" id="password" name="password" title="Password" value="${password}"/>
            </div>
            <div class="config-item">
                <span class="config-item-title">Save message to file</span>
                <input class="config-item-checkbox" type="checkbox" id="save_to_file" name="save_to_file" title="Save message to file" />
            </div>
            <div class="config-item">
                <span class="config-item-title">Receive</span>
                <button class="config-button" type="submit" id="submitBtn" name="submitBtn">Receive Message From Queue</button>
            </div>
            <div class="config-item">
                <span class="config-item-title">Message Content</span>
                <textarea class="config-item-content" id="message_content" name="message_content" title="Message Content">${message_content}</textarea>
            </div>
            <div class="config-item">
                <span class="config-item-title">Message Properties</span>
                <div style="margin-left: 25%; font-size: 10px; border: solid 1px #a9a9a9; width: 60%">
                    <c:forEach var="props" items="${propertiesMap}" varStatus="cnt">
                        <c:out value="${props.key} = ${props.value}"/><br/>
                        <%--<c:if test="${cnt.index %2 == 1}">--%>
                            <%--<br/>--%>
                        <%--</c:if>--%>
                    </c:forEach>
                </div>
            </div>
            <div class="config-item">
                <span class="config-item-title">Error Message</span>
                <textarea class="config-item-error" id="error_message" name="error_message" title="Error Message">${error_message}</textarea>
            </div>
            <input type="hidden" id="interface_name" name="interface_name" value="${interface_name}">
        </div>
    </form>
</div>
<span style="clear:both; z-index:1000; overflow:hidden; bottom:10px; left:5px;position:fixed !important;color: #e9e9e9">Author: Charkey@ODC;Cooperator: 大头森@ODC</span>
<script type="application/javascript" src="${ctx}/static/jquery-2.0.3.min.js"></script>
<script type="application/javascript">
    function selectQueueName() {
        $("#queue_name").val($("#queue_name_list").find("option:selected").text());
    }
</script>
</body>
</html>

